// Copyright (C) 2022 Linlexiao
#include "ansedit.h"

#include <QDebug>
AnsEdit::AnsEdit(QWidget *parent) : QTextEdit(parent) { qDebug() << "inti"; }

void AnsEdit::keyPressEvent(QKeyEvent *event) {
    if (event->key() == Qt::Key_Enter || event->key() == Qt::Key_Return) {
        emit enterPressed();
    } else
        QTextEdit::keyPressEvent(event);
}
